




C Fundamental Test 1

1) Which of the following is the first operating system developed using C programming language?

Windows
DOS
Mac
UNIX

Show Answer

The correct option is (d).
Explanation:
C programming language is invented for developing an operating system called UNIX. By 1973, the complete UNIX OS is developed using C.

2) The C compiler used for UNIX operating system is

cc
gcc
vc++
Borland

Show Answer

The correct option is (a).
Explanation:
Compiler used for UNIX is 'cc' their full form is C compiler. gcc is compiler for linux. Borland and vc++ is compiler for windows.

3) Which of the following is a logical AND operator?

||
!
&&
None of the above

Show Answer

The correct option is (c).
Explanation:
The && is called logical AND operator. If both operands are non-zero, then the condition becomes true.
The || is called logical OR operator. If any of the two operands are non-zero, then the condition becomes true.
The ! is called logical NOT operator. It is used for reversing the logic state of its operand.

4) Which format specifier is used for printing double value?

%Lf
 %L
 %lf
None of the above

Show Answer

The correct option is (c).
Explanation:
The %lf format specifier is used for printing the double value in a C program.

5) Which of the following statement is used to free the allocated memory space for a program?

vanish(var-name);
remove(var-name);
erase(var-name);
free(var-name);

Show Answer

The correct option is (d).
Explanation:
The memory allocated by malloc(), calloc(), or realloc() function is deallocated by using the library function free(var-name).












Please Share





